home *** CD-ROM | disk | FTP | other *** search
- i = "1";
- while(noOfB >= i)
- {
- bonuslife_y = getProperty("bonuslife" add i, _Y);
- bonuslife_y += "6";
- setProperty("bonuslife" add i, _Y, bonuslife_y);
- if("390" < bonuslife_y)
- {
- bat_x = getProperty("/bat", _X);
- bat_left = bat_x - batWidth / "2";
- bat_right = bat_x + batWidth / "2";
- bonuslife_x = getProperty("bonuslife" add i, _X);
- bonuslife_left = bonuslife_x - "10";
- bonuslife_right = bonuslife_x + "10";
- if(bonuslife_left >= bat_left and bat_right >= bonuslife_right)
- {
- tellTarget("/soundFX")
- {
- gotoAndStop("bonuslife");
- play();
- }
- trace("You\'ve just got BONUS LIFE");
- lives_left += "1";
- power_up = "bonuslife";
- call("reset_capsules");
- removeMovieClip("bonuslife" add i);
- onscreen_B = "0";
- }
- else
- {
- removeMovieClip("bonuslife" add i);
- onscreen_B = "0";
- }
- }
- i += "1";
- }
-